package api

import (
	"github.com/gin-gonic/gin"
	"user3/api/handler"
	"user3/middleware"
)

func LoadRouter(r *gin.Engine) {
	r.POST("/user/register", handler.Register)
	r.POST("/user/login", handler.Login)
	api := r.Group("/api").Use(middleware.JwtAuthMiddleware())
	{
		api.POST("/add", handler.Add)
	}
}
